package com.roy.minimq.remoting.domain.entity;

import com.roy.minimq.remoting.domain.entity.common.Pair;
import com.roy.minimq.remoting.domain.netty.NettyRequestProcessor;

import java.util.concurrent.ExecutorService;

/**
 * @author ：楼兰
 * @date ：Created in 2021/8/9
 * @description:
 **/
public interface RemotingServer extends RemotingService {

    void registerProcessor(final int requestCode, final NettyRequestProcessor processor,
                           final ExecutorService executor);

    void registerDefaultProcessor(final NettyRequestProcessor processor, final ExecutorService executor);

    Pair<NettyRequestProcessor, ExecutorService> getProcessorPair(final int requestCode);

}
